package com.example.finance_oa.controller;


import com.example.comment_oa.pojos.Standard;
import com.example.comment_oa.response.AjaxResponse;
import com.example.finance_oa.service.StandardService;
import org.checkerframework.checker.units.qual.A;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@CrossOrigin
@RequestMapping("/financeOa")
public class standardController {
    @Autowired
    StandardService standardService;

    @RequestMapping("standard/clbz")///{bxkm}
    public AjaxResponse allStandard(@RequestBody Standard standard){


        return AjaxResponse.success(standardService.allStandard(standard));
    }
  //新增或修改
    @RequestMapping("standard/saveStandard")
    public AjaxResponse saveStandard(@RequestBody Standard standard){
        return AjaxResponse.success(standardService.saveStandard(standard));
    }
}
